home *** CD-ROM | disk | FTP | other *** search
- property firstChannel, loopButtonList, waitFlag
- global gLoopButton, gErrorTrapFlag
-
- on birth me
- set gLoopButton to EMPTY
- set loopButtonList to []
- set firstChannel to 7
- set waitFlag to 0
- add(loopButtonList, birth(script "Loop Button Class", 7, 7, "flagButtonHandler( gMenuObject , 1 )", "RCA-06VO03", "RCA-06RO03"))
- add(loopButtonList, birth(script "Loop Button Class", 7, 8, "flagButtonHandler( gMenuObject , 2 )", "RCA-06VO04", "RCA-06RO04"))
- add(loopButtonList, birth(script "Loop Button Class", 7, 9, "flagButtonHandler( gMenuObject , 3 )", "RCA-06VO05", "RCA-06RO05"))
- return me
- end
-
- on update me
- if gErrorTrapFlag then
- set gErrorTrapFlag to 0
- exit
- end if
- if objectp(gLoopButton) then
- process(gLoopButton)
- else
- set whichbutton to 0
- repeat with rollChannel = firstChannel to firstChannel + count(loopButtonList) - 1
- if rollOver(rollChannel) then
- set whichbutton to rollChannel - firstChannel + 1
- exit repeat
- end if
- end repeat
- if (whichbutton > 0) and not soundBusy(1) then
- hideOtherActors(me)
- activate(getAt(loopButtonList, whichbutton))
- else
- if waitFlag then
- set waitFlag to 0
- else
- repeat with button in loopButtonList
- changeBitmap(button)
- end repeat
- end if
- end if
- end if
- end
-
- on waitOneFrame me
- set waitFlag to 1
- end
-